Machine Code Programs are Predicates Too
نویسنده
چکیده
I present an interpretation of machine language programs as boolean expressions Source language programs may also be so interpreted The correctness of a code generator can then be expressed as a simple re lationship between boolean expressions Code generators can then be calculated from their speci cation Introduction A predicate divides its domain in two In the speci cation of computational behaviour we wish to divide the set of all imaginable computations in two parts acceptable computations and unacceptable computations Predicates provide a convenient way of expressing this division In this paper we are interested in two kinds of computational behaviour the behaviour speci ed by high level language programs in terms of source level variables and the behaviour speci ed by machine language programs in terms of registers and memory By using predicate logic as a common framework to describe both forms of behaviour we can relate them and write down the logical relationship that should exist between the input and output programs of a compiler This relationship serves as a speci cation from which we can derive a code generator Except for the derivation of an example code generator all proofs and derivations have been omitted Where proofs are not straight forward an outline is presented Proofs of most of the theorems can be found in my thesis Norvell
منابع مشابه
Compositional Abstraction for Concurrent Programs
We present a methodology for automatically constructing an abstraction of concurrent programs against safety specifications based on finite state machine. And then automatically extract an initial abstract model from source code using predicate abstraction and theorem proving. However, the process of extracting a finite model from a program using predicate abstraction can be exponential in the ...
متن کاملAn Executable Intermediate Representation for Incremental Global Compilation of Prolog
The programming language Prolog has built-in predicates which enable the modiication of a program at runtime. This makes the global compilation of Pro-log programs a complex task. This paper presents an intermediate representation which enables fast incre-mental global compilation of Prolog. This intermediate representation is based on the Vienna Abstract Machine (VAM) with its two versions, th...
متن کاملOpaque Predicates Detection by Abstract Interpretation
Code obfuscation and software watermarking are well known techniques designed to prevent the illegal reuse of software. Code obfuscation prevents malicious reverse engineering, while software watermarking protects code from piracy. An interesting class of algorithms for code obfuscation and software watermarking relies on the insertion of opaque predicates. It turns out that attackers based on ...
متن کاملCodifying Structural Regularities of Object-Oriented Programs
Well-written object-oriented programs exhibit many structural regularities ranging from naming and coding conventions, through design patterns, to architectural constraints. Tools and environments that aid a software developer in constructing, understanding or modifying object-oriented programs should be able to reason about and manipulate such regularities. We codify structural regularities of...
متن کاملAn Experiment in Abstract Machine Design
SUMMARY In this article we present Typed Feature Structures as an extension of Prolog, and show how to come up with a compilation scheme and an abstract machine using a design methodology based on partial evaluation. First we define the transformations used by our partial evaluator. Then we present the design methodology which we will use later. Next, we clarify the notion of Typed Feature Stru...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 1994